import axios from '../../utils/request';
/**
 * 模块名: 选课
 */

// 选择课程
export const created = (data: { student_id: number; lessonsSortId: number }) => {
  return axios.request({
    url: '/student-course',
    method: 'post',
    data,
  });
};

// 选课详情
export const get = (id: number) => {
  return axios.request({
    url: '/student-course/' + id,
    method: 'get',
  });
};

// 退课
export const del = (id: number) => {
  return axios.request({
    url: '/student-course/' + id,
    method: 'delete',
  });
};

export default {
  created,
  get,
  del,
};
